package com.cskaoyan.service;

import com.cskaoyan.bean.data.CartCheckedData;
import com.cskaoyan.bean.data.CartIndexData;
import com.cskaoyan.bean.vo.CartAddVo;
import com.cskaoyan.model.MarketCart;

import java.util.List;
import java.util.Map;

/**
 * @Author Pudding
 * @Date 2024/6/13 16:50
 */
public interface CartService {
    Integer goodsCount(Integer userId);

    List<MarketCart> getUserCartListByUserId(Integer userId);

    CartIndexData cartIndex(Integer userId);

    MarketCart findByPost(Integer userId, Integer goodsId, Integer productId);

    int create(Integer userId, CartAddVo cartAddVo);

    int modify(MarketCart updateCart);

    int checked(Integer userId, CartCheckedData cartCheckedData);

    Map checkout(int userId, Map<String,Object> parameterMap);

    Map index(int userId);

    int deleteById(Integer userId, Integer goodsId, Integer productId);

    int updateNumber(Map map);

    int deleteByProductIds(Map<String,List<Integer>> map);

    List<MarketCart> findCheckedGoods(Integer userId);

    MarketCart findByCartId(Integer cartId);
}
